<%@ page contentType="text/html;charset=UTF-8" language="java" %>
<%@ include file="../comm-header.jsp" %>
<!DOCTYPE html>
<html lang="zh-CN">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1" />
<c:set var="contextPath" value="${pageContext.request.contextPath}" scope="application"/>
<title>授权</title>
<script src="${contextPath}/resources/js/jquery.min.js"></script>
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<link rel="shortcut icon" href="${contextPath}/favicon.ico" type="image/x-icon" />
<link href="${contextPath}/resources/yhzx/css/bootstrap.css" rel="stylesheet">
<link href="${contextPath}/resources/yhzx/css/login.css" rel="stylesheet">
<link href="${contextPath}/resources/yhzx/css/entypo-icon.css" rel="stylesheet">
<script src="/UcConfig/uc/GlobalParams.js"></script>
</head>

<body style="background-color:#f9f9fb">

    <div class="">
		<div class="">
		   <ol class="breadcrumb lj">
              <li><a><i class="glyphicon glyphicon-home"></i></a></li>
			  <li>授权</li>						  	
		   </ol>
		</div>
	</div>
    

	<div class="main">
    <div class="panel panel-default">
       <div class="panel-body panel-body1-left">		
           <div class="col-md-12 control-label">
              <p>您正在使用用户中心账号访问</p>
           </div>
           <div class="col-md-12 control-label">
              <img style="width:78px;" src="${contextPath}/resources/yhzx/img/authorize-pic1.png" id="headPortrait">
              <div class="author-pic">
                 <div class="pic-text1">提供授权的信息</div>
                 <div class="pic-text2">提供增值的服务</div>
              </div>
              <img style="width:78px;" src="${contextPath}/resources/yhzx/img/authorize-pic2.png">
           </div>
           <div class="clear"></div>
           <div class="col-md-12 control-label">
           		<p></p>
           		<p>授权后，您将允许应用访问或操作以下数据，为您提供更加优质的服务：<a>查看用户中心服务协议</a></p>
          		<p>用户中心账号信息；</p>
          		<!-- <p>店铺内商品信息；</p>
          		<p>交易相关订单和客户信息；</p> -->
           		<p>授权成功后，您也可以随时在<a> 授权管理 </a>里查看和取消授权</p>
          		<!-- <p style="float:left;">用户中心账户名：<div class="zh-name"></div><a>换个账户名？</a></p> -->

           </div>
           <div class="col-sm-5 control-label">
           		<div class="btn-sure ">
					<form id='confirmationForm' name='confirmationForm' action='${pageContext.request.contextPath}/oauth/authorize'
						  method='post'>
						<input type="hidden" name="client_id" value="${param.client_id}"/>
						<input type="hidden" name="scope" value="${param.scope}"/>
						<input type="hidden" name="response_type" value="${param.response_type}"/>
						<input type="hidden" name="redirect_uri" value="${redirect_uri}"/>
						<input type="hidden" name="state" value="${param.state}"/>
						<input type="hidden" name="client_secret" value="${param.client_secret}"/>
						<input type="hidden" name="appIconUri" value="${appIconUri}" id="appIconUri"/>
						<input name='user_oauth_approval' value='true' type='hidden'/>
						<button type="submit" class="btn btn1">确定</button>
					</form>
					
					<form id='denialForm' name='denialForm' action='${pageContext.request.contextPath}/oauth/authorize' method='post'>
						<input type="hidden" name="client_id" value="${param.client_id}"/>
						<input type="hidden" name="scope" value="${param.scope}"/>
						<input type="hidden" name="response_type" value="${param.response_type}"/>
						<input type="hidden" name="redirect_uri" value="${redirect_uri}"/>
						<input type="hidden" name="state" value="${param.state}"/>
						<input type="hidden" name="client_secret" value="${param.client_secret}"/>
						<input type="hidden" name="appIconUri" value="${appIconUri}" id="appIconUri"/>
						<input name='user_oauth_approval' value='false' type='hidden'/>
						<button type="submit" class="btn btn1 btn-white">取消</button>
					</form>

                </div>
           </div>
                    
	    </div>
    </div>
	</div>
</body>
<script type="text/javascript">
	var appIconUri = $('#appIconUri').val();
	document.getElementById("headPortrait").src= FILE_PATH +appIconUri;
</script>
</html>
